# -*- coding: utf-8 -*-
from cmsdj.content.models import Content
from django.shortcuts import render_to_response, get_object_or_404
from django.views.decorators.csrf import csrf_protect
from django.template import RequestContext

@csrf_protect
def details (request, slug):
    content = get_object_or_404(Content, slug = slug, published = True)
    return render_to_response ('content/details.html',locals(),context_instance=RequestContext(request))

@csrf_protect
def details_to_print (request, slug):  
    content = get_object_or_404(Content, slug = slug, published = True)  
    return render_to_response ('content/details_v_printer.html',locals(),context_instance=RequestContext(request))
